<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<meta name=ProgId content=Word.Document>
<meta name=Generator content="Microsoft Word 9">
<meta name=Originator content="Microsoft Word 9">
<link rel=File-List
href="./viewer,%20tracer%20and%20sea%20food_files/filelist.xml">
<title>Using the Concept Hierarchy</title>
<!--[if gte mso 9]><xml>
 <o:DocumentProperties>
  <o:Author>Michael Joe</o:Author>
  <o:Template>Normal</o:Template>
  <o:LastAuthor>michael joe</o:LastAuthor>
  <o:Revision>20</o:Revision>
  <o:TotalTime>65</o:TotalTime>
  <o:Created>2001-04-26T23:10:00Z</o:Created>
  <o:LastSaved>2001-04-27T04:32:00Z</o:LastSaved>
  <o:Pages>2</o:Pages>
  <o:Words>451</o:Words>
  <o:Characters>2575</o:Characters>
  <o:Company>NYU</o:Company>
  <o:Lines>21</o:Lines>
  <o:Paragraphs>5</o:Paragraphs>
  <o:CharactersWithSpaces>3162</o:CharactersWithSpaces>
  <o:Version>9.2720</o:Version>
 </o:DocumentProperties>
</xml><![endif]--><!--[if gte mso 9]><xml>
 <w:WordDocument>
  <w:Zoom>200</w:Zoom>
 </w:WordDocument>
</xml><![endif]-->
<style>
<!--
 /* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{mso-style-parent:"";
	margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman";
	mso-fareast-font-family:"Times New Roman";}
p
	{margin-right:0in;
	mso-margin-top-alt:auto;
	mso-margin-bottom-alt:auto;
	margin-left:0in;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman";
	mso-fareast-font-family:"Times New Roman";}
tt
	{mso-ascii-font-family:"Courier New";
	mso-fareast-font-family:"Courier New";
	mso-hansi-font-family:"Courier New";
	mso-bidi-font-family:"Courier New";}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;
	mso-header-margin:.5in;
	mso-footer-margin:.5in;
	mso-paper-source:0;}
div.Section1
	{page:Section1;}
-->
</style>
<meta name=Author content="Ralph Grishman">
<!-- saved from url=(0063)http://cs.nyu.edu/courses/spring01/G22.2590-001/jet/scorer.html -->
</head>

<body lang=EN-US style='tab-interval:.5in'>

<div class=Section1>

<h2>The JET Pattern Viewer, Pattern Graph Viewer and Pattern Match Tracing with
Sea Food</h2>

<p class=MsoNormal>The JET system uses <i>patterns</i>.&nbsp;The patterns are
stored in a pattern file and loaded into the system during initialization and
can also be reloaded by using the JET Console&#8217;s menu <span style='font-family:
Arial'>File | <span style="mso-spacerun: yes">&nbsp;</span>Reload Patterns</span>.
The Pattern Viewer views the patterns as a tree based on the structures in
which they are organized in the pattern file. It&#8217;s also used for tracing
pattern matching during execution. The Pattern Graph Viewer views the patterns
as a tree based the directed graph the patterns form.</p>

<h3>The pattern file</h3>

<p class=MsoNormal>The patterns are defined in a pattern file.&nbsp; The file
format is defined elsewhere. </p>

<p>Pattern files are suggested to use the file extension&nbsp;&nbsp; <tt><span
style='font-size:10.0pt;font-family:"Courier New"'>.pat</span></tt>. (If so,
the file chooser can use a filter to focus on the pattern files only.)</p>

<h3>Loading the patterns</h3>

<p class=MsoNormal>A pattern file can be loaded into the system during
initialization by including a line of the form </p>

<p class=MsoNormal style='margin-right:.5in;mso-margin-top-alt:auto;mso-margin-bottom-alt:
auto;margin-left:.5in'><tt><span style='font-size:10.0pt;font-family:"Courier New"'>Pattern.fileName</span></tt>
= <i>filename</i></p>

<p class=MsoNormal>in the JET properties file. </p>

<h3>Pattern Viewer</h3>

<p>Launch the Pattern Viewer from JET Console&#8217;s menu <span style='font-family:
Arial'>Patterns | View Patterns</span>. The patterns shown are from the pattern
file defined in the JET properties file. All the patterns are listed in the
first subtree &#8220;Patterns&#8221; with their productions shown as their children. Only
the patterns with action(s) are listed in the second subtree &#8220;Pattern Sets&#8221;,
grouped by their pattern sets, and with their actions shown as their children.
Action nodes have the icon of a <b><i>yellow fish</i></b>.</p>

<p>The Pattern Viewer can also load patterns from another pattern file. Use <span
style='font-family:Arial'>File | Open</span> to open a pattern file.</p>

<h3>Pattern Graph Viewer</h3>

<p>Launch the Pattern Graph Viewer from JET Console&#8217;s menu <span
style='font-family:Arial'>Patterns | View Pattern Graphs</span>. The patterns
shown are from the pattern file defined in the JET properties file. The
patterns form a directed graph. The graph is shown as a tree in the viewer. An
edge and its destination vertex are shown as a tree node. Every vertex in the
graph is named as &#8220;NODE_K&#8221;, where K is a unique number for the vertex. Every
edge in the graph is named as the production it represents, <i>e.g.</i> [token
case=cap]. For simplicity, downstream of a vertex with multiple in-edges is
shown only for the first time the vertex is added to the tree. Null edges are
introduced when necessary (in case of * and +, see the &#8220;pattern classes&#8221; file).
Action nodes have the icon of a <b><i>yellow fish</i></b>.</p>

<p>The Pattern Graph Viewer can also load patterns from another pattern file.
Use <span style='font-family:Arial'>File | Open</span> to open a pattern file.</p>

<h3>Pattern Match Tracing</h3>

<p>Pattern matching during execution can be traced by using tracing options in
the JET Console&#8217;s <span style='font-family:Arial'>Patterns | Pattern Match
Trace</span> and <span style='font-family:Arial'>Patterns | Pattern Apply Trace</span>.
When the trace for certain patterns is on, the trace will be printed in the
Console and if a Pattern Viewer is open, the matched patterns will be
highlighted in the Pattern Viewer with its node&#8217;s icon changed. (Matched patterns
have the icon of a <b><i>pink octopus</i></b>, shown only in the &#8220;Patterns&#8221;
subtree. Applied patterns have the icon of a <b><i>red crab</i></b>, shown only
in the &#8220;Pattern Sets&#8221; subtree.) Reloading a pattern file by <span
style='font-family:Arial'>File | Reload Patterns</span> will updated the <span
style='font-family:Arial'>Patterns | Pattern Match Trace</span> and <span
style='font-family:Arial'>Patterns | Pattern Apply Trace</span> submenus. The
Pattern Viewer and Pattern Graph Viewer should be restarted to have the
underlying patterns updated.</p>

<p>More tracing and graphical editing functions could be added to the Pattern Graph
Viewer in the future but just enjoy the sea food at this time.</p>

<p><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>

<p><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>

</div>

</body>

</html>
